#include <stdio.h>

int main()
{
	FILE* pf = fopen("C:\\Users\\32669\\Desktop\\date.txt", "w+");
	if (pf == NULL)
	{
		perror("fopen");
		return 1;
	}
	int i = 0;
	for (i = 'a'; i <= 'z'; i++)
	{
		fputc(i, pf);
	}
	rewind(pf);
	if (pf == NULL)
	{
		perror("fopen.r");
		return 1;
	}
	char arr[10];
	if (fgets(arr, sizeof(arr), pf))
	{
		printf(arr);
	}
	fclose(pf);
}